package com.mall.module.system.domain.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

/**
 * 更新部门DTO
 */
@ApiModel("更新部门参数")
@Data
public class UpdateDeptDTO {

    @ApiModelProperty(value = "部门ID", required = true, example = "1")
    @NotNull(message = "部门ID不能为空")
    private Long deptId;

    @ApiModelProperty(value = "部门名称", example = "技术部")
    @Size(max = 50, message = "部门名称长度不能超过50个字符")
    private String name;

    @ApiModelProperty(value = "父部门ID", example = "0", notes = "0表示根部门")
    private Long parentId;

    @ApiModelProperty(value = "显示顺序", example = "1")
    private Integer orderNum;

    @ApiModelProperty(value = "部门编码", example = "TECH")
    @Size(max = 20, message = "部门编码长度不能超过20个字符")
    private String deptCode;

    @ApiModelProperty(value = "部门类型", example = "2", notes = "1:公司, 2:部门, 3:小组")
    private Integer deptType;

    @ApiModelProperty(value = "部门负责人ID", example = "1")
    private Long leaderId;

    @ApiModelProperty(value = "联系电话", example = "010-12345678")
    private String phone;

    @ApiModelProperty(value = "邮箱", example = "tech@company.com")
    private String email;

    @ApiModelProperty(value = "部门地址", example = "北京市朝阳区xxx街道")
    private String address;

    @ApiModelProperty(value = "部门描述", example = "负责公司技术研发工作")
    @Size(max = 500, message = "部门描述长度不能超过500个字符")
    private String description;

    @ApiModelProperty(value = "状态", example = "1", notes = "0:禁用, 1:启用")
    private Integer status;
} 